Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update http dependency name #1884

Merged
merged 1 commit into from
Sep 28, 2021
Merged

Update http dependency name #1884

merged 1 commit into from
Sep 28, 2021

Conversation

trask
Copy link
Member

@trask trask commented Sep 26, 2021

Built on top of #1890 EDIT: no longer as #1890 has been merged to main

@trask trask force-pushed the update-http-dependency-name branch from 060f1a1 to 26b306b Compare September 26, 2021 05:36
@trask trask closed this Sep 26, 2021
@trask trask reopened this Sep 26, 2021
@trask trask force-pushed the update-http-dependency-name branch from e2b9bbd to f639b71 Compare September 26, 2021 18:04
@trask trask force-pushed the update-http-dependency-name branch from f639b71 to 53162ff Compare September 27, 2021 04:59
@trask trask marked this pull request as ready for review September 27, 2021 17:10
@trask trask force-pushed the update-http-dependency-name branch from 53162ff to ddd5f3f Compare September 27, 2021 18:45
class UrlParser {

/**
* Returns the path portion of the url.
*
* <p>Returns {@code null} if the path cannot be extracted from url for any reason.
*/
@Nullable
static String getPathFromUrl(String url) {
Copy link
Contributor

@heyams heyams Sep 27, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like URL.getPath() does the same thing? it handles case like ?query and #. Can we convert url string to an URL object and then use getPath directly, and we can get rid of UrlParser?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

constructing URL objects is slow: open-telemetry/opentelemetry-java-instrumentation#3699

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it will be nice to compare the perf side by side. was URLStreamHandler.parseURL slow or the constructor of URL?
inside the constructor it will invoke parseURL from the handler.. I am wondering if the newer version of java has improved it..

@trask trask merged commit 38ae66d into main Sep 28, 2021
@trask trask deleted the update-http-dependency-name branch September 28, 2021 21:30
@kryalama kryalama added this to the 3.2.0-BETA.4 milestone Sep 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants